package cn.dkk.create_design.builder.ConsturctorBuilder;

/**
 * @author dkk
 * @date 2022/7/10
 * @desc 构造方法建造者测试类
 */
public class Test {
    public static void main(String[] args) {
        Phone phone = new Phone.Builder()
                .cpu("intel i7 12")
                .memory("金士顿内存")
                .mainBoard("微星主板")
                .screen("三星屏幕")
                .build();
        System.out.println(phone);
        System.out.println("--------------------");
        Computer computer = new Computer.Builder()
                .cpu("i5")
                .mainBoard("华硕")
                .screen("三星")
                .memory("西数")
                .build();
        System.out.println(computer);
    }
}
